<!-- 司机详情 -->
<template>
  <div class="dashboard-container driver-detail">
    <el-card style="margin: 20px" shadow="never">
      <el-tabs v-model="activeName" @tab-click="handleClick">
        <!-- 司机基本信息 -->
        <el-tab-pane label="基本信息" name="basicInformation"
          ><driver-info></driver-info
        ></el-tab-pane>
        <!-- 驾驶证信息 -->
        <el-tab-pane label="驾驶证信息" name="truckLicense"
          ><driver-license></driver-license
        ></el-tab-pane>
      </el-tabs>
    </el-card>
  </div>
</template>
<script>
import DriverInfo from './components/driver-info.vue'
import DriverLicense from './components/driver-license.vue'

export default {
  components: {
    DriverInfo,
    DriverLicense
  },

  data() {
    return {
      activeName: 'basicInformation'
    }
  },
  methods: {
    // 面板切换
    handleClick(tab, event) {
      console.log(tab, event)
    }
  }
}
</script>
<style lang="scss" scoped>
.active {
  color: #ff643d;
}
</style>

<style lang="scss" scoped>
::v-deep .el-tabs__item.is-top:nth-child(2) {
  padding-left: 25px;
}

::v-deep .el-tabs__item.is-active {
  padding-left: 20px;
  font-weight: bolder;
  color: #20232a;
  font-size: 16px;
}

::v-deep .el-tabs__active-bar {
  height: 3px;
  background-color: #e15536;
  padding-left: 25px;
}

.driver-detail {
  ::v-deep .el-container {
    flex-direction: column;
    margin-left: 0px;
  }
  .in {
    height: calc(100vh - 205px);
  }
  .aside-box {
    background: #ffffff;
    border-radius: 4px;
    padding: 24px 37px 24px 37px;
    box-sizing: border-box;
    ::v-deep .el-aside {
      padding-bottom: 14px;
      width: 100% !important;
      display: flex;
      background-color: #ffffff;
      border-bottom: 1px solid #e5e7ec;
      text-align: left;
      font-size: 14px;
      .aside-item {
        cursor: pointer;
        &:first-child {
          margin-right: 53px;
          padding-left: 25px;
        }
      }
      .aside-item.active {
        font-size: 16px;
        font-weight: bold;
        color: #20232a;
        &:after {
          content: '';
          display: block;
          background-color: #e15536;
          height: 3px;
          width: 49px;
          margin: 0 auto;
          position: relative;
          top: 14px;
        }
      }
    }
  }
}
</style>
